﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using BranchOfSansar.Sansar.Register;

namespace BranchOfSansar.Register.Main
{
    public partial class frmAddSchedule : Form
    {
        public PaySchedule addItem;
        public frmAddSchedule()
        {
            InitializeComponent();
        }

        private void cmdSave_Click(object sender, EventArgs e)
        {
            if (!Globals.DoValidation(panelControl1))
            {
                return;
            }
            addItem = new PaySchedule();
            addItem.PayDate = dateEdit1.DateTime;
            addItem.PayAmount = Convert.ToDecimal(txtAmount.Text);
            //addItem.txtDesc = "Төхөөрөмжийн үнэ";
            this.DialogResult = System.Windows.Forms.DialogResult.Yes;
        }

        private void frmAddSchedule_Load(object sender, EventArgs e)
        {
            dateEdit1.DateTime = DateTime.Now;
        }
    }
}
